package suncertify.util;

/**
 * Class for notification view classes about model events
 */
public class Notification {
    private Object event;
    private String message;
    private Object data;

    /**
     * constructs notification with specified event
     * @param event model event
     */
    public Notification(Object event) {
        this.event = event;
    }

    /**
     * constructs notification with specified event and data
     * @param event model event
     * @param data event data
     */
    public Notification(Object event, Object data) {
        this.event = event;
        this.data = data;
    }

    /**
     * constructs notification with specified event and message
     * @param event model event
     * @param message model message
     */
    public Notification(Object event, String message) {
        this.event = event;
        this.message = message;
    }

    /**
     * constructs notification object with specified event, message and data
     * @param event model event
     * @param message event message
     * @param data event data
     */
    public Notification(Object event, String message, Object data) {
        this.event = event;
        this.message = message;
        this.data = data;
    }

    /**
     * returns notification event
     * @return event
     */
    public Object getEvent() {
        return event;
    }

    /**
     * returns event message
     * @return message
     */
    public String getMessage() {
        return message;
    }

    /**
     * returns event data
     * @return data
     */
    public Object getData() {
        return data;
    }
}
